package top.bug.blog.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import top.bug.blog.entity.dto.comments.CommentsAddRequest;
import top.bug.blog.entity.dto.comments.CommentsQueryRequest;
import top.bug.blog.entity.po.Comments;
import top.bug.blog.entity.vo.comments.CommentsVO;

import javax.servlet.http.HttpServletRequest;

/**
 * @author <a href="https://github.com/jiusi66">九思.</a>
 * @email 10837907@qq.com
 * @from <a href="https://www.52bug.top">递归茶馆-www.52bug.top</a>
 * @description 评论 接口
 */
public interface CommentsService extends IService<Comments> {

    /**
     * 获取评论树
     */
    Page<CommentsVO> getCommentTreeByTarget(CommentsQueryRequest queryRequest);

    /**
     * 新增评论
     */
    void addComment(CommentsAddRequest addRequest, HttpServletRequest request);

}